package router

import (
	"gin-build/hanlder/service"

	"github.com/gin-gonic/gin"
)

func Router() *gin.Engine {
	r := gin.Default()
	userGroup := r.Group("/user")
	userGroup.POST("/register", service.Register)
	userGroup.GET("/getUser", service.GetUser)
	userGroup.GET("/usernameList", service.UsernameList)
	userGroup.GET("/addFriend", service.AddFriend)
	return r
}
